package com.itcam.cm.manager.controller;


import com.itcam.cm.manager.service.SysRoleService;
import com.itcam.cm.manager.service.SysUserRoleService;
import com.itcam.cm.model.dto.system.AssginRoleDto;
import com.itcam.cm.model.dto.system.SysRoleDto;
import com.itcam.cm.model.entity.system.SysRole;
import com.itcam.cm.model.vo.common.Result;
import com.github.pagehelper.PageInfo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import java.util.Map;

@RestController
@CrossOrigin(allowCredentials = "true" , originPatterns = "*" , allowedHeaders = "*")
@RequestMapping("/admin/system/sysUserRole")
public class SysUserRoleController {

    @Autowired
    SysUserRoleService sysUserRoleService;

    @PostMapping("doAssign")
    public Result doAssign(@RequestBody AssginRoleDto assginRoleDto){
        sysUserRoleService.doAssign(assginRoleDto);
        return Result.ok(null);
    }

}
